S

SideButton Dashboard Knowledge Module

SideButton Dashboard Run Logs — Knowledge Module Reference

SideButton Dashboard knowledge module — UI selectors, data model, and page states documenting Run Logs.

Available free v0.4.0 Browser
$ sidebutton install SideButton Dashboard
Download ZIP
Path
/run-logs
Verified
2026-02-21
Confidence
96%
Role playbooks
0
Pack
SideButton Dashboard
Domain
sidebutton.local

What This Is

The Run Logs module covers three related views for monitoring and inspecting workflow executions: the Run Log List (history + live running workflows with KPI stats), the Run Log Detail (full event timeline for a completed run), and the Execution View (real-time streaming log for an in-progress execution). Together they form the execution observability surface of the SideButton dashboard.

URL Patterns

ViewURLNotes
Run Log List/run-logsNo sidebar nav entry — reached via Skills "View Run Logs" link or other in-app navigation
Run Log Detail/run-logs/{id}id is the run log record ID (not run_id)
Execution ViewNo URLInternal view state only — triggered by navigateToExecution(workflowId, runId). Cannot be deep-linked

View 1: Run Log List (RunLogView.svelte)

Page Structure

+--[Header: "Run Logs" h1 + item count badge]--[Clear All] [Reload]--+
|  [.kpi-bar] (only when runs exist)                                  |
|    [.kpi-hero: time saved today value + label]                      |
|    [.kpi-time-breakdown: This Week / This Month / All Time rows]    |
|    [.kpi-divider]                                                   |
|    [.kpi-stats: Runs Today + Success Rate]                          |
|                                                                      |
|  [Currently Running section] (only when running workflows exist)    |
|    h2 with .pulse dot + "Currently Running ({count})"               |
|    [.running-list: .running-card buttons]                           |
|                                                                      |
|  [.history-section]                                                  |
|    h2 "History" (only shown when running section is also visible)   |
|    [.run-list: .run-card buttons]                                   |
|                                                                      |
|  [.empty-state] (when no runs and not loading)                      |
|  [.loading-state] (while fetching)                                  |
+----------------------------------------------------------------------+

Key Elements

Header

ElementSelectorNotes
Page headingh1 containing "Run Logs"Inside .header-left
Item count badge.item-countShows runs.length
Clear All button.btn-secondary in headerInitiates inline confirm flow — does NOT open a dialog
Reload button.reload-btnRefetches run logs and running workflows immediately

Clear All Inline Confirm

Clicking "Clear All" does NOT use window.confirm(). It replaces the button area with an inline confirm UI in-place.

ElementSelectorNotes
Confirm text.confirm-textText: "Clear all logs?"
Confirm delete button.btn-dangerText: "Yes, Clear". Executes the clear operation
Cancel button.btn-secondary (inside confirm)Text: "Cancel". Dismisses confirm without action

KPI Stats Bar

Visible only when runs.length > 0. Hidden entirely during empty state.

ElementSelectorNotes
Stats bar container.kpi-barHorizontal row; absent when no runs
Hero value.kpi-hero-valueLarge green text — time saved today (formatted duration string)
Hero label.kpi-hero-labelText: "Time Saved Today"
Time breakdown rows.kpi-time-breakdownContains rows for This Week, This Month, All Time
Time row label.kpi-time-labele.g., "This Week", "This Month", "All Time"
Time row value.kpi-time-valueFormatted duration for that period
Vertical divider.kpi-dividerSeparates hero + breakdown from stats column
Stats column.kpi-statsContains Runs Today count + Success Rate percentage

Running Workflows Section

Shown only when $runningWorkflows.length > 0.

ElementSelectorNotes
Section headingh2 with .pulse dotAnimated dot + "Currently Running ({count})" text
Running list.running-listFlex/grid container of running cards
Running cardbutton.running-cardClickable — calls navigateToRunningExecution(run_id, workflow_id) → opens ExecutionView
Card header.running-headerContains workflow title + StatusBadge showing "running"
Card meta.running-metaShows run_id + started time

History Section

ElementSelectorNotes
History section container.history-sectionAlways rendered when runs exist
History headingh2 "History"Only rendered when the Running section is also visible (i.e., hasRunning is true)
Run list.run-listContainer of completed run cards
Run cardbutton.run-cardClickable — calls navigateToRunLogDetail(run.id) → opens Run Log Detail
Card header.run-headerContains workflow title + StatusBadge
Card meta.run-metaShows run_id + duration + timestamp

StatusBadge Component

Used on both running cards and history cards.

Status valueVisual
"running"Blue badge (animated)
"success"Green badge
"failed"Red badge

Empty and Loading States

ElementSelectorNotes
Empty state.empty-stateClock SVG icon + h3 "No Run History" + "Workflow executions will appear here."
Loading state.loading-stateText: "Loading run logs..."

WebSocket Behavior

  • Subscribes to running-workflows-changed events on mount
  • When a running workflow completes, triggers auto-refresh of run logs after a 500ms delay
  • Unsubscribes on component destroy

Data Sources

  • listRunLogs(50) — fetches up to 50 most recent completed run logs
  • getRunningWorkflows() — fetches currently active executions

View 2: Run Log Detail (RunLogDetailView.svelte)

Page Structure

+--[Back btn] [.header-actions: Delete confirm area]--+
|  [.run-info container, max-width 900px]              |
|    [.title-row: h1 workflow title + StatusBadge]     |
|    [.meta-grid: auto-fill grid of .meta-item cards]  |
|    [.params-list] (conditional: when params exist)   |
|    [h2 "Events ({count})"]                           |
|    [.events-container: .event-item rows]             |
|                                                      |
|  [.not-found] (when ID not found)                   |
|  [.error] (on API error)                             |
|  [.loading] (while fetching)                         |
+------------------------------------------------------+

Key Elements

Header

ElementSelectorNotes
Back button.back-btnText: "Back". Calls navigateToRunLogs()
Header actions area.header-actionsRight side of header — contains delete button or inline confirm
Delete buttonbutton inside .header-actionsInitial state — triggers inline confirm

Delete Inline Confirm

Clicking Delete replaces the button with inline confirm UI in-place. Does NOT use window.confirm().

ElementSelectorNotes
Confirm text.confirm-textText: "Delete this log?"
Confirm delete button.btn-dangerText: "Yes, Delete". Deletes and navigates to run logs list
Cancel button.btn-secondaryText: "Cancel". Returns to delete button

After delete completes: navigateToRunLogs() is called automatically.

Run Info

ElementSelectorNotes
Info container.run-infomax-width: 900px, centered
Title row.title-rowContains h1 (workflow title) + StatusBadge component
Meta grid.meta-gridgrid-template-columns: repeat(auto-fill, minmax(..., 1fr))
Meta item card.meta-itemOne card per metadata field
Meta label.meta-item .labelUppercase text — field name (e.g., "RUN ID", "DURATION")
Meta value.meta-item .valueField value
Monospace value.meta-item .value.monoUsed for IDs and timestamps

Meta grid fields (one card each): Run ID, Workflow ID, Duration, Events, Triggered By, Timestamp.

Parameters Section

Shown only when runLog.params has one or more entries.

ElementSelectorNotes
Params list.params-listGrid of parameter cards
Param card.param-itemOne per parameter
Param name.param-namePurple text — parameter key
Param value.param-valueMonospace — parameter value

Events Section

ElementSelectorNotes
Section headingh2Text: "Events ({count})"
Events container.events-containerMonospace font family
Event row.event-itemDepth-based left padding (calc(depth * N px))
Event index.event-indexRow number (0-based)
Event type.event-typeType label with color class (see below)
Event message.event-messageContent of the event

Event Type CSS Classes

Event typeCSS classColor
workflow_start.event-runBlue
workflow_end.event-endGreen
step_start.event-stepGray
step_end.event-step-endPurple
error.event-errorRed
log.event-logOrange / warning

Terminal States

ElementSelectorNotes
Not found.not-foundText: "Run log not found."
Error.errorAPI error message text
Loading.loadingText: "Loading run log..."

View 3: Execution View (ExecutionView.svelte)

Page Structure

+--[.back-btn (disabled while running)] [.header-info] [.header-actions]--+
|  [.error-banner] (on error)                                               |
|                                                                            |
|  [.log-header: event count + run ID]                                       |
|  [.log-container: scrolling monospace log area]                            |
|    [.empty-state with .spinner] (while waiting for first event)            |
|    -- or --                                                                |
|    [.log-entry rows]                                                       |
+----------------------------------------------------------------------------+

Key Elements

Header

ElementSelectorNotes
Back button.back-btnDisabled (disabled attr) while $isRunning. Enabled when completed
Header info.header-infoContains h1 (workflow title or "Execution" if title unknown) + status badge
Status badge (running).status.runningBlue — contains .pulse animated dot
Status badge (completed).status.completedGreen
Header actions.header-actionsRight side — contains Stop or Done button
Stop button.btn-stopRed-tinted. Visible while $isRunning. Calls stopWorkflow(runId)
Done button.btn-primaryVisible when completed. Navigates back

Error Banner

ElementSelectorNotes
Error banner.error-bannerShown when an error occurs. Contains error message text

Log Area

ElementSelectorNotes
Log header.log-headerShows event count + run ID
Log container.log-containerMonospace font, scrollable. Auto-scrolls to bottom as new entries arrive
Empty state.empty-stateShown when $logs.length === 0. Contains .spinner + "Waiting for execution events..."
Spinner.spinnerSpinning blue circle (CSS animation)
Log entry.log-entryOne row per event. Depth-based left padding
Log time.log-timeTimestamp column
Log type.log-typeType label with color class (see below)
Log message.log-messageContent text

Log Entry Type CSS Classes

Event typeCSS classColor
workflow_start.log-runBlue
workflow_end (success).log-successGreen
error.log-errorRed
step_start / step_end.log-stepGray
result / step_end with result.log-resultPurple
log with level warn.log-warnOrange

WebSocket Behavior

  • Calls initWebSocket() on mount — opens real-time connection for log event streaming
  • $effect watches $logs.length — auto-scrolls .log-container to bottom on every new entry
  • stopWorkflow(runId) stops the execution and sets $isRunning to false
  • Back button remains disabled (disabled attribute) while $isRunning === true

Data Models

RunLogMetadata

FieldTypeNotes
idstringRun log record ID (used in /run-logs/{id} URL)
workflow_idstringWorkflow identifier
workflow_titlestringDisplay name
statusstring"success", "failed", or "running"
duration_msnumberTotal execution time in milliseconds
event_countnumberNumber of events recorded
timestampstringISO 8601 datetime of execution start
triggered_bystringOrigin: "user", "agent", etc.

RunLog (full, fetched for detail view)

FieldTypeNotes
metadataRunLogMetadataSee above
eventsWorkflowEvent[]Complete ordered event list
paramsRecord<string, string>Input parameters provided at execution time

WorkflowEvent

FieldTypeNotes
typestringworkflow_start, workflow_end, step_start, step_end, error, log
action_idstringWorkflow ID this event belongs to
action_titlestringWorkflow display name
step_indexnumber0-based step position
step_typestringStep type name
step_detailsstringStep detail text
successbooleanOutcome — present on workflow_end and step_end events
messagestringError or log message text
resultstringStep result text (shown as .log-result / .event-step-end)
levelstringFor log events: "info", "warn", "error"
depthnumberIndentation level — drives left padding in both detail and execution views
timestampstringISO 8601 datetime of this specific event

RunningWorkflow

FieldTypeNotes
run_idstringActive run ID (used to navigate to ExecutionView)
workflow_idstringWorkflow identifier
workflow_titlestringDisplay name
started_atstringISO 8601 datetime when execution started

States

RunLogView States

StateTriggerVisual
LoadingInitial fetch in progress.loading-state "Loading run logs..."
EmptyFetched, no runs found.empty-state with clock icon, h3 "No Run History"
Populated (no running)Runs exist, none active.kpi-bar + .history-section only
Populated (with running)Runs exist + active runs.kpi-bar + Running section + h2 "History" + history section
Clear All: confirm pendingClicked "Clear All".confirm-text + .btn-danger + .btn-secondary replace button
Auto-refreshRunning workflow completes500ms delay then data refetched silently

RunLogDetailView States

StateTriggerVisual
LoadingFetching run log.loading "Loading run log..."
LoadedFetch succeeds.run-info with title, meta grid, optional params, events
Not FoundID not in records.not-found "Run log not found."
ErrorAPI failure.error with error message
Delete: confirm pendingClicked Delete.confirm-text + .btn-danger + .btn-secondary
DeletedConfirmed deleteNavigates to run logs list

ExecutionView States

StateTriggerVisual
Running (no events yet)Started, WebSocket connected, no events.empty-state with .spinner + "Waiting for execution events..."
Running (events streaming)Events arriving via WebSocket.log-entry rows; auto-scrolling; Back disabled; Stop button visible
CompletedFinal event received.status.completed badge; Done button; Back enabled
ErrorError event or API failure.error-banner visible
StoppedUser clicked StopstopWorkflow() called; $isRunning set false; transitions to completed state

Common Tasks

  1. View run history: Navigate to /run-logs — history cards appear in .run-list sorted most-recent-first
  2. Open a completed run: Click a .run-card in the history section → navigates to /run-logs/{id}
  3. Open a live execution: Click a .running-card in the Running section → opens ExecutionView with real-time log stream
  4. Read KPI stats: Load /run-logs with existing runs — .kpi-hero-value shows time saved today; .kpi-stats shows Runs Today count and Success Rate
  5. Delete a run log: In Run Log Detail, click Delete button → .confirm-text appears → click "Yes, Delete" → returns to list
  6. Clear all logs: In Run Log List, click "Clear All" → confirm text appears → click "Yes, Clear" → all logs deleted
  7. Reload logs: Click .reload-btn — immediately refetches both run logs and running workflows
  8. Stop a running execution: In ExecutionView, click .btn-stopstopWorkflow(runId) called → transitions to completed state
  9. Read event details: In Run Log Detail, inspect .event-item rows — color-coded by .event-* class; indented by depth
  10. Read parameters: In Run Log Detail, .params-list shows input params if any were provided (absent if no params)

Tips

  • Running vs History are separate data sources: Running workflows come from getRunningWorkflows() (live store); history comes from listRunLogs(50). They render in separate sections and refresh independently
  • History heading is conditional: The h2 "History" heading only renders when there are also running workflows visible. When there are no running workflows, the list renders without a heading
  • KPI bar is data-dependent: .kpi-bar is absent from the DOM when runs.length === 0. Do not assert its presence in empty-state tests
  • Depth field drives indentation: Both .event-item (detail) and .log-entry (execution) use depth to calculate left padding — deeper nesting = more indentation
  • ExecutionView has no URL: It is rendered as an internal view state — navigating directly to any URL will not open it. It must be reached via a running-card click or navigateToExecution() call
  • Auto-scroll is reactive: ExecutionView scrolls .log-container to the bottom on every new log entry via a Svelte $effect. The container is always showing the latest event during a live run
  • id vs run_id: RunLogMetadata.id is the database record ID used for the detail URL. run_id (on RunningWorkflow) is the active execution handle. These are distinct fields with different uses
  • WebSocket refresh delay: When a running workflow completes, RunLogView waits 500ms before refetching — the history list may briefly not show the just-completed run

Gotchas

  • Clear All and Delete use INLINE confirm, not window.confirm(): Clicking these buttons does NOT open a browser dialog. They transform the button area into .confirm-text + .btn-danger + .btn-secondary in-place. Automation must click through the two-step sequence
  • ExecutionView Back button is disabled while running: .back-btn has the disabled attribute while $isRunning. Attempting to click it during execution will have no effect — wait for completion or click Stop first
  • No deep link to ExecutionView: navigateToExecution() sets internal view state only. There is no URL to construct. Cannot be reached by navigating the browser address bar
  • Run Log List has no sidebar nav entry: /run-logs is not listed in the left sidebar. It must be reached from Skills "View Run Logs" or programmatic navigation — do not expect a sidebar button
  • listRunLogs(50) cap: Only the 50 most recent logs are fetched. Older entries are not paginated — they are simply omitted from the list view
  • Empty event type falls back: If an event's type does not match a known class (.event-run, .event-end, etc.), no color class is applied — the row renders in default text color
  • Params section absent when no params: .params-list is not rendered at all when runLog.params is empty or undefined — do not assert its presence unless params are known to exist
  • WebSocket in ExecutionView is separate from RunLogView WebSocket: Each view manages its own WebSocket subscription. The execution view streams live events; the list view only subscribes to running-workflows-changed for refresh triggers
  • SPA 404 on direct /run-logs navigation: As with all routes, loading /run-logs directly in the browser address bar before the SPA shell is loaded returns a Fastify 404 JSON response. Must navigate through the SPA root first